package com.example.mister5aside;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.EditText;

public class SettingsActivity extends Activity {

	/** Called when the activity is first created. */
	@Override
	public void onCreate(Bundle savedInstanceState) {
	    super.onCreate(savedInstanceState);
	       // Display the fragment as the main content.
  getFragmentManager().beginTransaction()
          .replace(android.R.id.content, new SettingsFragment())
          .commit();

	    //setContentView(R.layout.activity_settings);
	    // TODO Auto-generated method stub
	}
	
    public void save_settings(View v)
    {
    	
    	
    	EditText set_time_long = (EditText) findViewById(R.id.editText1);
        Intent returnIntent = new Intent();
        returnIntent.putExtra("time_long", Integer.parseInt(set_time_long.getText().toString()));
        setResult(RESULT_OK,returnIntent);     
        finish();
    }
}
